package builder2;

/**
 * @author: rensiyu
 * @create: 2021-09-01 14:21
 * @description:
 **/
public class ConcreteBuilder extends Builder{
    private Product product;
    public ConcreteBuilder() {
        product = new Product();
    }
    @Override
    public void partA() {
        product.setPartA("创建A");
        System.out.println("创建A.........");
    }

    @Override
    public void partB() {
        product.setPartB("创建B");
        System.out.println("创建B.........");
    }

    @Override
    public void partC() {
        product.setPartC("创建C");
        System.out.println("创建C.........");
    }

    @Override
    public Product getProduct() {
        return product;
    }
}
